#if !defined(AFX_MINDIGITAL_H__84E446A1_BAB7_11D2_AE44_C04D05C10000__INCLUDED_)
#define AFX_MINDIGITAL_H__84E446A1_BAB7_11D2_AE44_C04D05C10000__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// MinDigital.h : header file
//

/////////////////////////////////////////////////////////////////////////////
// CMinDigital window
#include "..\Resource.h"

class CMinDigital : public CStatic
{
// Construction
public:
	CMinDigital();

// Attributes
public:
	enum CClockStyle { XDC_SECOND, XDC_NOSECOND };
	static COLORREF origin;

// Operations
public:
	CClockStyle GetStyle() const { return m_style;}
	CClockStyle SetStyle(CClockStyle style);
	COLORREF GetColor() const { return m_color;}
	COLORREF SetColor(COLORREF color);
	BOOL GetAlarm() const { return m_bAlarm;}
	BOOL SetAlarm(BOOL bAlarm = TRUE);

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CMinDigital)
	protected:
	virtual void PreSubclassWindow();
	//}}AFX_VIRTUAL

// Implementation
public:
	int m_oldyear;
	int m_oldmonth;
	int m_oldday;
	int m_oldhour;
	int m_oldminute;

	virtual ~CMinDigital();

	// Generated message map functions
protected:
	//{{AFX_MSG(CMinDigital)
	afx_msg void OnTimer(UINT nIDEvent);
	afx_msg void OnDestroy();
	afx_msg BOOL OnEraseBkgnd(CDC* pDC);
	afx_msg void OnPaint();
	//}}AFX_MSG

private:

	BOOL			m_bAlarm;
	COLORREF    m_color;

	UINT			m_w;
	UINT			m_h;
	CClockStyle m_style;
	BITMAP		m_bm;
	UINT			m_nCount;
	HBITMAP		m_hBitmap[14];
	UINT			m_nTimer;

	void			Output(UINT digit, UINT pos);

	DECLARE_MESSAGE_MAP()
};

/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_MINDIGITAL_H__84E446A1_BAB7_11D2_AE44_C04D05C10000__INCLUDED_)
